package com.gw.smscheck.service.sys.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.gw.smscheck.dao.sys.SysIconMapper;
import com.gw.smscheck.entity.sys.SysIcon;
import com.gw.smscheck.service.sys.SysIconService;
@Service
public class SysIconServiceImpl implements SysIconService {
	@Autowired
	private SysIconMapper sysIconMapper;
	@Override
	public Integer add(SysIcon sysIcon) {
		return sysIconMapper.add(sysIcon);
	}
	@Override
	public List<SysIcon> findAll() {
		return sysIconMapper.findAll();
	}
	@Override
	public PageInfo<SysIcon> pageSelect(SysIcon dto) {
		PageHelper.startPage(dto.getPage(), dto.getRows(), "create_time desc");// 排序
		List<SysIcon> resultList = sysIconMapper.pageSelect(dto);
		PageInfo<SysIcon> pageInfo = new PageInfo<>(resultList);
		return pageInfo;
	}
	@Override
	public SysIcon findById(Integer dto) {
		return sysIconMapper.findById(dto);
	}
	@Override
	public Integer update(SysIcon sysIcon) {
		return sysIconMapper.update(sysIcon);
	}
	@Override
	public Integer delByIds(String[] ids) {
		return sysIconMapper.delByIds(ids);
	}
}

